package train_array.day2;

import java.util.Scanner;

public class code4 {

    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = Integer.parseInt(sc.nextLine());
        int len = 2*n-1;
        String[] str= sc.nextLine().split(" ");
        long sum = 0;
        for(int i=0;i<str.length;i++){
            System.out.print(str[i]+" ");
            sum += Math.abs(Integer.parseInt(str[i]));
        }
        System.out.println("-----");
        System.out.println(sum);

    }

}
